1. Field of the Invention
The present invention relates to an image processing method and an image processing apparatus for use in a digital color copier, facsimile machine, etc., in particular relating to an image processing method and an image processing apparatus wherein black character areas in an image are detected so that the image is processed in an appropriate manner based on the detected result.
2. Description of the Prior Art
In recent years, digital color copiers and color laser printers have widely spread because of rapid development of OA apparatus into digitalization and increase of the demands for color image output. In order to realize high quality imaging and high performance functions with these image forming apparatus, image processing techniques play an important role. In a digital color copier, a color original is captured by separating it into three colors, R(red), G(green) and B(blue), and the captured data is subjected to various image processes so as to produce a converted set of image data of four colors, C(cyan), M(magenta), Y(yellow) and K(black), which in turn is used to form a color image on a recording medium. Here, the reason the K signal is added is that if reproduction of achromatic colors such as black and the like is tried by superimposition of the three colors, C, M and Y, color turbidness and color misregistration will occur.
In order to improve against these drawbacks, black generation and undercolor removal(UCR) are executed. However, even with these processes, it is not possible to execute a perfect undercolor removal, so the black characters cannot be reproduced to be black and also color blurring will occur around the black characters. In order to improve against these drawbacks, there have been proposals for improving image quality by detecting black character areas in originals and subjecting those areas to a treatment for enhancing the reproducibility of characters, such as emphasis filtering, black emphasis, and the like. For example, Japanese Patent Application Laid-Open Hei 9 No. 139843, discloses an image processing apparatus in which edges of black characters are detected from image data of an original composed of chromatic and achromatic color components, outer portions with respect to the edges are distinguished from inner portions and the data values of the chromatic and achromatic color components of pixels determined as belonging to outer edge portions and the data values of the chromatic color component of pixels determined as belonging to inner edge portions are replaced with minimum values from among the individual observed pixels and their surrounding pixels while the pixels determined as within inner edge portions are edge emphasized, that is, the data value of the achromatic color component of the pixels are enhanced.
In the above prior art, inner and outer sides with respect to edges are determined so that the data values of the areas on the outer side are replaced with predetermined minimum values while only the areas on the inner side are edge emphasized to thereby avoid occurrence of white voids around characters and thickening of black characters. However, there is a good chance of color blurring around black characters when the data values of observed pixels are replaced with predetermined minimum values with a risk of fine characters and thin lines being deleted. Further, in this prior art, since each pixel is determined to belong to either the inner side or the outer side with respect to an edge, based on whether the coefficient of the second-derivative filter is positive or negative, there is a possibility that the density of pixels which have been determined to reside inside an edge might become lower than the background density by an emphasis filtering process, thus possibly generating contours around characters. Therefore, the method of discriminating the inner portions from the outer portions and subjecting them to different processes will encounter drawbacks in that small characters and fine lines may be deleted, color blurring and contours may arise around characters and the image quality may become lowered.
The present invention has been devised in view of the above problems and it is therefore an object of the present invention to provide an image processing method and an image processing apparatus wherein not only the occurrence of white voids but also the occurrence of contours, color blurring, which all would arise around black characters, can be avoided.
In order to achieve the above object, the present invention is configured as follows:
In accordance with the first aspect of the present invention, an image processing method, comprises the steps of:
subjecting a plurality of color components constituting color image input data to an emphasis judgment filtering process;
comparing each result with a corresponding predetermined reference value and summing the compared results;
comparing the sum with a predetermined threshold;
judging whether an emphasis process is effected for the color image input data based on the comparison; and
replacing the color image input data with achromatic color data when the judgment determines that the emphasis process should not be effected.
In accordance with the second aspect of the present invention, the image processing method having the above first feature is characterized in that the achromatic color data is the mean value of the multiple color components of the color image input data.
In accordance with the third aspect of the present invention, the image processing method having the above first feature is characterized in that the reference value is determined based on the background data of the color image input data.
In accordance with the fourth aspect of the present invention, an image processing apparatus at least having an edge detecting means for detecting edges of black characters based on color image input data, comprises:
an emphasis judgment filtering means for subjecting a plurality of color components constituting color image input data to an emphasis judgment filtering process;
a comparing means for comparing the result as to each color component output from the emphasis judgment filtering means, with a corresponding predetermined reference value;
a signal generating means for generating an emphasis setup judgment signal based on the result from the comparing means; and,
a signal replacing means for replacing the color image input data with achromatic color data when the judgment determines that the emphasis process should not be effected.
In accordance with the fifth aspect of the present invention, the image processing apparatus having the above fourth feature is characterized in that the signal replacing means calculates the mean value of the multiple color components of the color image input data to produce achromatic color data and replaces the color image input data with the achromatic color data.
In accordance with the sixth aspect of the present invention, the image processing apparatus having the above fourth feature is characterized in that the reference values set up in the comparing means are determined based on the background information of the color image input data.
In the method written as the first feature, first, each of the color components of the color image input data is subjected to an emphasis judgment filtering process, and the result is compared to a predetermined reference value, for example, with reference to the sign of the resultant value, i.e., checking if the value is positive or negative, or the background data (the value of the background density), or the like. An area of pixels having negative values after the emphasis judgment filtering process can produce white voids around characters. An area of pixels having values smaller than the background density value can produce contours around characters. The effect of the above process enables previous detection of these defects.
Then, the comparison results for individual color components are summed and the sum is compared to a predetermined threshold so as to determine whether an emphasis process is to be effected. When the judgment determines that the emphasis process should not be effected, the color image input data is replaced with achromatic color data.
Since color blurring often occurs at black character edges, replacement of the data of the areas, for which the emphasis process should not be effected, with data close to black (achromatic color) enables prevention of color blurring as well as avoidance of the disappearance of small characters and fine lines.
In the method written as the second feature, when it is determined that no emphasis process should be effected, from the judgment as to whether the emphasis process is to be done, the mean value of the multiple color components of the color image input data is used as the achromatic color data to replace the color image input data. For example, when the color image input data is of C, M and Y, the mean value of C, M and Y is calculated to replace each of the C, M and Y values. Thus, replacement of the C, M and Y component values with their average enables neutralization of the density differences between C, M and Y color components and generation of data close to an achromatic color. In this way, it is possible to generate achromatic color data in a simple method.
In the method written as the third feature, when each of the color components of the color image input data is subjected to an emphasis judgment filtering process and the result is compared to a predetermined reference value, the background data (the background density value) is used as the reference value. An area of pixels having negative values after the emphasis judgment filtering process can cause white voids around characters. An area of pixels having values smaller than the background density value, even if they are positive, can produce contours around characters if uniform emphasis is effected. For countermeasures against these drawbacks, use of the background data of the color image input data as the reference value makes it possible to exclude the areas which could produce such contours and hence effect appropriate emphasis filtering process for black character edges.
In the configuration written as the fourth feature, first the emphasis judgment filtering means subjects each of the color components of the color image input data to an emphasis judgment filtering process, and the comparing means compares the result with a predetermined reference value, for example, with reference to the sign of the resultant value, i.e., checking if the value is positive or negative, or the background data (the value of the background density), or the like. An area of pixels having negative values after the emphasis judgment filtering process can produce white voids around characters. An area of pixels having values smaller than the background density value can produce contours around characters. The effect of the above process enables previous detection of these defects.
Then, the comparison results for individual color components output from the comparing means are summed and the sum is compared to a predetermined threshold so as to determine whether an emphasis process is to be effected. The signal generating means generates an emphasis setup judgment signal. The signal converting means replaces the color image input data with achromatic color data when it is judged from the emphasis setup signal that the emphasis process should not be effected.
Since color blurring often occurs at black character edges, replacement by signal converting means of the data of the areas, for which the emphasis process should not be effected, with data close to black (achromatic color) enables prevention of color blurring as well as avoidance of the disappearance of small characters and fine lines.
In the configuration written as the fifth feature, when the color image input data is subjected to an emphasis judgment filtering process by the emphasis judgment filtering means and it is determined that no, emphasis process should be effected, the signal converting means calculates the mean value of the values of the multiple color components of the color image input data and replaces each of the color component values with that mean value. Thus, replacement of the multiple color values with their mean value enables neutralization of the density differences between the individual color components and generation of data close to an achromatic color. In this way, it is possible to generate achromatic color data in a simple method.
In the configuration written as the sixth feature, when each of the color components of the color image input data is subjected to an emphasis judgment filtering process by the emphasis judgment filtering means and the result is compared to a predetermined reference value, set beforehand in the comparing means. In this configuration, the background data (the background density value) is used as the reference value. An area of pixels having negative values after the emphasis judgment filtering process may cause white voids around characters. An area of pixels having values smaller than the background density value, even if they are positive, can also produce contours around characters if uniform emphasis is effected. For countermeasures against these drawbacks, use of the background data of the color image input data as the reference value makes it possible to exclude the areas which could produce such contours and hence effect appropriate emphasis filtering process for black character edges.